<style>
#enterPutniNalog{
	width:1000px;
}
#enterPutniNalog table td{
	text-align:center;
	vertical-align:top;
}
#enterPutniNalog table input{
	margin:0px;
	float:none;
}#enterPutniNalog table input[type=button]{
	width:20px;
	height:20px;
	padding:0px;
}
#enterPutniNalog label.block{
	width:100px;
}
#enterPutniNalog fieldset label.block{
	width:65px;
}
#enterPutniNalog textarea{
	width:70px;
	height:30px;
	margin:0px auto;
}
#enterPutniNalog input[type=text].xshort{
	width:20px;
}
#enterPutniNalog input[type=text].short{
	width:30px;
}
#enterPutniNalog input[type=text].medium{
	width:45px;
}
#enterPutniNalog input[type=text].large{
	width:70px;
}
#enterPutniNalog fieldset{
	width:94%;
	float:left;
}
#enterPutniNalog fieldset.half{
	width:44%;
}
</style>
<h1>Ulaz putnih naloga</h1>
<form id="enterPutniNalog" method="post" action="javascript:void(0)" onsubmit="if(pnTestEnterForm()){submitForm(this,'putni_nalozi.php','POST','afterEnterPutniNalog',1)}" class="area">
	<input type="hidden" name="a" value="addEnter" />
	
	<label class="left" for="broj">broj naloga:</label>
	<input type="text" name="broj" id="broj" onchange="LoadRSDoc('putni_nalozi.php?a=updatePrethodnoStanje&broj='+escape(this.value),'updatePrethodnostanjeBrojila')" />
	
	<div style="float:right; width:200px;">
		<label class="left" for="prethodna_km">prethodno stanje brojila:</label>
		<input type="text" class="medium" name="prethodna_km" id="prethodna_km" value="" />
	</div>
	
	
	<br clear="all" />
	<table id="enterTable" width="100%">
		<tr class="head" align="center">
			<td rowspan="2">datum</td>
			<td colspan="2">relacija</td>
			<td colspan="2">vreme</td>
			<td rowspan="2">pređeno</td>
			<td rowspan="2">stanje brojila</td>
			<td colspan="3">gorivo</td>
			<td colspan="3">ostali troskovi</td>
			<td rowspan="2"></td>
		</tr>
		<tr class="head" align="center">
			<td>od</td>
			<td>do</td>
			<td>odlazak</td>
			<td>dolazak</td>
			<td>kol.</td>
			<td>cena</td>
			<td>br.računa</td>
			<td>iznos</td>
			<td>opis</td>
			<td>br.računa</td>
		</tr>
		<tr id="1">
			<td><input type="text" class="dateInput" name="datum_1" id="datum_1" /></td>
			<td><textarea name="relacija_od_1" id="relacija_od_1" onkeyup="this.value=this.value.replace(/\r*\n/g,' ');"></textarea></td>
			<td><textarea name="relacija_do_1" id="relacija_do_1" class="large" onkeyup="this.value=this.value.replace(/\r*\n/g,' ');"></textarea></td>
			<td><input type="text" name="time_out_1" id="time_out_1" class="short" maxlength="5" onkeyup="if(this.value.length==2 && this.value.match(/^\d+$/)){this.value+=':'}" /></td>
			<td><input type="text" name="time_in_1" id="time_in_1" class="short" maxlength="5" onkeyup="if(this.value.length==2 && this.value.match(/^\d+$/)){this.value+=':'}" /></td>
			<td><input type="text" name="predjeno_1" id="predjeno_1" class="short" onkeyup="this.value=this.value.replace(/[^\d]/g,''); sumKM(this);" /></td>
			<td><input type="text" name="stanje_1" id="stanje_1" class="medium" /></td>
			<td><input type="text" name="gorivo_kol_1" id="gorivo_kol_1" class="xshort" /></td>
			<td><input type="text" name="gorivo_iznos_1" id="gorivo_iznos_1" class="medium" /></td>
			<td><input type="text" name="gorivo_brrac_1" id="gorivo_brrac_1" class="medium" /></td>
			<td><input type="text" name="tros_iznos_1" id="tros_iznos_1" class="medium" /></td>
			<td><input type="text" name="tros_opis_1" id="tros_opis_2" /></td>
			<td><input type="text" name="tros_brrac" id="tros_brrac" class="medium" /></td>
			<td>
				<input type="button" class="novi" onclick="pnEnterAddRow(this)" />
				<input type="button" class="delete" onclick="pnEnterDelRow(this)" />
			</td>
		</tr>
	</table>
	<br clear="all" />
	<input type="submit" value="unesi" />
</form>